<link rel="stylesheet" href="/static/layui/css/layui.css"  media="all">
<link rel="stylesheet" href="/static/layui/css/cropper.css"  media="all">

<script src="/static/layui/layui.js" charset="utf-8"></script>
<script>
    var $,
            layer,
            defaultImg = "/static/shearphoto/images/background.jpg", //默认背景图片
            deleteImgUrl = "/static/shearphoto/php/delete.php", //删除图片
            uploadImgUrl = "/static/shearphoto/php/upload.php", //上传图片
            cropImgUrl = "/static/shearphoto/php/shearphoto.php", //裁剪图片
            relativeUrl = "", //图片存放顶级文件
            styleUrl = "shearphoto", //js css images 存放相对路径
            cropwidth = 500;//图片裁剪生成宽度
    _token = "{{csrf_token()}}" //token
    uploads_url = "/upload" //原图上传路径
    saveUrl = "upload"; //图片存放文件夹
    layui.config({
        base: '/static/shearphoto/js/'
    }).use('cropper');
</script>